#include "Generate_C_std.h"

class Pattern_foreach_end : public Pattern
{
	bool match (Statement* that)
	{
		end = new Wildcard<Foreach_end>;
		return that->match (end);
	}

	void generate_code(Generate_C* gen)
	{
		INST (buf, "foreach_end",
			end->value->array, end->value->iter->value);
	}

protected:
	Wildcard<Foreach_end>* end;
};


CREATE(Pattern_foreach_end);
